﻿using FreeSql.DataAnnotations;

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using ZhonTai.Admin.Core.Entities;
using ZhonTai.Industry.Domain.DeviceFormula;
using ZhonTai.Industry.Domain.ProductRoute;
using ZhonTai.Industry.Domain.ProductSeries;

namespace ZhonTai.Industry.Domain.ProductModel
{
    /// <summary>
    /// 产品模型
    /// </summary>
    /// <remarks>产品模型</remarks>
    [Table(Name = "prd_product_model")]
    public class ProductModelEntity : EntityBase
    {
        /// <summary>
        /// 编号
        /// </summary>
        public string ProductCode { get; set; }

        /// <summary>
        /// 名称
        /// </summary>
        public string ProductName { get; set; }

        /// <summary>
        /// 产品系列ID
        /// </summary>
        public long ProductSeriesId { get; set; }

        /// <summary>
        /// 配方ID
        /// </summary>
        public long FormulaId { get; set; }

        /// <summary>
        /// 产品路线ID
        /// </summary>
        /// <remarks>产品路线ID</remarks>
        public long ProductRouteId { get; set; }

        /// <summary>
        /// 排序
        /// </summary>
        public int Sort { get; set; }

        /// <summary>
        /// 启用
        /// </summary>
        /// <remarks>启用</remarks>
        public bool Enabled { get; set; }

        /// <summary>
        /// 工艺路线
        /// </summary>
        [Navigate(nameof(ProductRouteId))]
        public ProductRouteEntity ProductRoute { get; set; }

        /// <summary>
        /// 产品系列
        /// </summary>
        [Navigate(nameof(ProductSeriesId))]
        public ProductSeriesEntity ProductSeries { get; set; }

        /// <summary>
        /// 设备配方
        /// </summary>
        [Navigate(nameof(FormulaId))]
        public DeviceFormulaEntity DeviceFormula { get; set; }
    }
}